package dao.impl;

import dao.SCDao;
import mapper.SCMapper;
import mapper.StudentMapper;
import org.apache.ibatis.session.SqlSession;
import pojo.SC;
import pojo.Student;
import util.MybatisUtil;

import java.util.List;

public class SCDaoImpl implements SCDao {
    private static SqlSession session = null;
    @Override
    public List<SC> getGradeList(Student student) {
        List<SC> list=null;
        try {
            session = MybatisUtil.createSqlSession();
            list = session.getMapper(SCMapper.class).selectSCList(student);
            return list;
        }finally {
            session.close();
        }
    }
}
